/**
 * @param {string} command
 * @return {string}
 */
var interpret = function (command) {
  let res = ''
  for (let i = 0; i < command.length; ) {
    if (command[i] == 'G') {
      res += 'G'
      i++
    } else {
      if (command[i] == '(' && command[i + 1] != ')') {
        res += 'al'
        i += 4
      } else {
        res += 'o'
        i += 2
      }
    }
  }
  return res
}
